QT       += core gui

greaterThan(QT_MAJOR_VERSION, 4): QT += widgets

CONFIG += c++11

# You can make your code fail to compile if it uses deprecated APIs.
# In order to do so, uncomment the following line.
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000    # disables all the APIs deprecated before Qt 6.0.0

DEFINES += QT_DEPRECATED_WARNINGS
#开发模式需要添加预定义SHINEVV_DEVELOPER
#DEFINES += YINSHU_DEVELOPER
#用户模式需要注释掉
#DEFINES += YINSHU_DEVELOPER

contains(QT_ARCH,"arm64"){
    DEFINES -= YINSHU_DEVELOPER
}

contains(DEFINES,YINSHU_DEVELOPER){
    INCLUDEPATH += ../
    CONFIG += debug_and_release
    contains(QT_ARCH,"x86_64"){
        CONFIG(debug, debug|release){
            INCLUDEPATH += ../../third_yinshu/cpr/curl/include
            win32:{
                DEFINES += SHINEVV_WINDOWS
                DESTDIR=$$PWD/../../../out/yinshu_gw_winx64
                LIBS += $$PWD/../../../out/yinshu_gw_winx64/yinshu_gw.dll.lib \
                    wldap32.lib advapi32.lib \
                    $$PWD/../../../out/yinshu_gw_winx64/cpr_shared.dll.lib
            }
            unix: {
                DESTDIR=$$PWD/../../../out/yinshu_gw_linux_x64
                LIBS += $$PWD/../../../out/yinshu_gw_linux_x64/libyinshu_gw.so \
                $$PWD/yinshu_gw/bin/linux_x64/libcpr_shared.so \
                $$PWD/yinshu_gw/bin/linux_x64/libx264.so
            }
        } else {
            INCLUDEPATH += ../../third_yinshu/cpr/curl/include
            win32: {                
                DEFINES += SHINEVV_WINDOWS
                DESTDIR=$$PWD/yinshu_gw/bin/win_x64
                LIBS += $$PWD/yinshu_gw/lib/win_x64/yinshu_gw.dll.lib \
                    wldap32.lib advapi32.lib \
                    $$PWD/yinshu_gw/lib/win_x64/cpr_shared.dll.lib
            }
            unix:{
                DESTDIR=$$PWD/yinshu_gw/bin/linux_x64
                LIBS += $$PWD/yinshu_gw/bin/linux_x64/libyinshu_gw.so \
                $$PWD/yinshu_gw/bin/linux_x64/libcpr_shared.so \
                $$PWD/yinshu_gw/bin/linux_x64/libx264.so
            }
        }
    }
}else{
    INCLUDEPATH += $$PWD/yinshu_gw/include
    win32: {
        DEFINES += SHINEVV_WINDOWS
        DESTDIR=$$PWD/yinshu_gw/bin/win_x64
        LIBS +=  $$PWD/yinshu_gw/lib/win_x64/yinshu_gw.dll.lib \
            wldap32.lib advapi32.lib \
           $$PWD/yinshu_gw/lib/win_x64/cpr_shared.dll.lib
    }
    unix:{
        contains(QT_ARCH,"arm64"){
              DESTDIR=$$PWD/yinshu_gw/bin/linux_arm64
              LIBS += $$PWD/yinshu_gw/lib/linux_arm64/libyinshu_gw.so
        } else {
            DESTDIR=$$PWD/yinshu_gw/bin/linux_x64
            LIBS += $$PWD/yinshu_gw/bin/linux_x64/libyinshu_gw.so \
                $$PWD/yinshu_gw/bin/linux_x64/libcpr_shared.so \
                $$PWD/yinshu_gw/bin/linux_x64/libx264.so
        }
    }
}


contains(COMPILER, arm-linux-gnueabihf){
    message("compile for linux,arm-linux-gnueabihf")
}
contains(COMPILER, arm-linux-gnueabihf){
    message("compile for linux,arm-linux-gnueabihf")

}
SOURCES += \
    main.cpp \
    yinshu_gwwindow.cpp

HEADERS += \
    yinshu_gwwindow.h

FORMS += \
    yinshu_gwwindow.ui

